<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN""http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!-- saved from url=(0028)http://my.mtime.com/account/ -->
<html xmlns="http://www.w3.org/1999/xhtml" id="htmlTag">
<head id="head">
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=7">
    <meta http-equiv="Pragma" content="no-cache">
    <meta http-equiv="Expires" content="-1">
    <title>我的账户 - 城市猎人影院</title>

    <link href="../static/css/MyAccount/mytimeall.css" rel="stylesheet" type="text/css">
    <link href="../static/css/MyAccount/mytime_replace.css" rel="stylesheet" type="text/css">

    <link type="text/css" id="appStyle_0" rel="stylesheet" href="../static/css/MyAccount/account.css">

    <link rel="stylesheet" href="../static/css/MyAccount/mtime-vip.css">
    <link rel="stylesheet" type="text/css" href="../static/js/layui/css/layui.css" />
     <style type="text/css">
     .curr{margin : 0px 0px;}
   
    </style>

</head>
<body>
<!--<script type="text/javascript" src="./我的账户 - Mtime时光网_files/saved_resource"></script>-->
<div id="topbar" pn="M16_HeadNav">
	<div page="123.html" id="frist">
		</div>
	<!--   <div class="headbar head-mini" id="headbar"><h1 onclick="headTrackClick(&#39;M16_HeadNav_MiddleNav&#39;)"
                                                    pan="M16_HeadNav_MiddleNav"><a title="Mtime时光网"
                                                                                   href="http://www.mtime.com/">Mtime时光网</a>
    </h1>
        <dl class="headbarnav">
            <dd class=""><a href="http://www.mtime.com/" onclick="headTrackClick(&#39;M16_HeadNav_LeftNav_Index&#39;)"
                            pan="M16_HeadNav_LeftNav_Index">首页<i></i></a></dd>
            <dd class=""><a href="http://theater.mtime.com/"
                            onclick="headTrackClick(&#39;M16_HeadNav_LeftNav_Theater&#39;)"
                            pan="M16_HeadNav_LeftNav_Theater">购票<i></i></a></dd>
            <dd class=""><a href="http://mall.mtime.com/" onclick="headTrackClick(&#39;M16_HeadNav_LeftNav_Mall&#39;)"
                            pan="M16_HeadNav_LeftNav_Mall">正版商城<i></i></a></dd>
            <dd class=""><a href="http://news.mtime.com/" onclick="headTrackClick(&#39;M16_HeadNav_LeftNav_News&#39;)"
                            pan="M16_HeadNav_LeftNav_News">新闻<i></i></a></dd>
            <dd class=""><a href="http://live.mtime.com/" onclick="headTrackClick(&#39;M16_HeadNav_LeftNav_Live&#39;)"
                            pan="M16_HeadNav_LeftNav_Live">直播<i></i></a></dd>
            <dd class=""><a href="http://video.mtime.com/" onclick="headTrackClick(&#39;M16_HeadNav_LeftNav_Video&#39;)"
                            pan="M16_HeadNav_LeftNav_Video">视频<i></i><em>NEW</em></a></dd>
            <dd class=""><a href="http://movie.mtime.com/"
                            onclick="headTrackClick(&#39;M16_HeadNav_LeftNav_Recent&#39;)"
                            pan="M16_HeadNav_LeftNav_Recent">发现<i></i></a></dd>
            <dd class=""><a href="http://www.mtime.com/community/"
                            onclick="headTrackClick(&#39;M16_HeadNav_LeftNav_Community&#39;)"
                            pan="M16_HeadNav_LeftNav_Community">社区<i></i></a></dd>
            <dd class=""><a href="http://vip.mtime.com/" onclick="headTrackClick(&#39;M17_HeadNav_LeftNav_Vip&#39;)"
                            pan="M17_HeadNav_LeftNav_Vip">会员<i></i></a></dd>
        </dl>
        <div class="headcart" id="shopbox" onclick="headTrackClick(&#39;M16_HeadNav_MiniCart_Region&#39;)"
             pan="M16_HeadNav_MiniCart_Region"><i class="icocart"></i><b class="numcart" id="emGoodsCount"
                                                                         style="display:none;">0</b>
            <div class="headtip headcart-tip" style="display:none;"><p class="tips">您的购物车还是空的，赶快选购哦。</p></div>
        </div>
        <div class="headtool" id="loginbox"><i class="line"></i>
            <div class="headlogin"><a href="javascript:void(0);" title="认真的马场彻"
                                      onclick="headTrackClick(&#39;M16_HeadNav_User_Nickname&#39;)"
                                      pan="M16_HeadNav_User_Nickname"><img height="44" width="44"
                                                                           src="./我的账户 - Mtime时光网_files/head.gif"
                                                                           alt="认真的马场彻"><em>认真的马...</em><b></b><i></i></a>
            </div>
            <div class="headtip user-tip" style="display: none;">
                <div class="my-name">
                    <div id="userFace" style="position: absolute;left:0;top:0;width: 96px;height: 96px;"><a
                            class="my-pic __r_c_" href="http://my.mtime.com/" pan="M16_HeadNav_User_UserHead"><img
                            src="./我的账户 - Mtime时光网_files/head.gif" width="96" height="96"></a><a
                            href="http://vip.mtime.com/" class="userLevelIcon" data-pan="M17_HeadNav_User_Vipicon">
                        <i class="mtime-vip-user-level-icon mtime-vip-user-level-icon-03"></i>
                    </a></div>
                    <dl>
                        <dt><a href="http://my.mtime.com/" pan="M16_HeadNav_User_Nickname" class="__r_c_">认真的马场彻</a><a
                                href="http://vip.mtime.com/myprivilege" pan="M16_HeadNav_User_Vip" class="__r_c_"><span
                                id="topMenuLevelContainer">M0</span></a></dt>
                        <dd>
                            <div class="btns">
                                <a href="http://vip.mtime.com/" class="mtime-vip_btn-mini userInBoxVipIndexLink"
                                   data-pan="M17_HeadNav_User_Vip">会员俱乐部</a>
                                <p>
                                    <a data-pan="M17_HeadNav_User_Privilege"
                                       href="http://vip.mtime.com/privilege/">我的特权</a>
                                    <i class="mlr5">|</i>
                                    <a data-pan="M17_HeadNav_User_Mtimecoin" href="http://vip.mtime.com/mtimecoin/">时光币兑换</a>
                                </p>
                            </div>
                        </dd>
                    </dl>
                </div>
                <dl class="my-business fix">
                    <dd><a href="http://my.mtime.com/account/" pan="M16_HeadNav_User_Ticket" class="__r_c_">电影票订单</a>
                    </dd>
                    <dd><a href="http://my.mtime.com/account/ecommerce/orderList/" pan="M16_HeadNav_User_Order"
                           class="__r_c_">商品订单</a></dd>
                    <dd><a id="myCouponsCount" href="http://my.mtime.com/account/voucher/"
                           pan="M16_HeadNav_User_Voucher" class="__r_c_">我的优惠券</a></dd>
                    <dd><a id="myMtimeCardCount" href="http://my.mtime.com/account/moviecard/"
                           pan="M16_HeadNav_User_Card" class="__r_c_">我的礼品卡</a></dd>
                </dl>
                <div class="my-couptip" id="couponWillEndContainer" style="display:none;"><i></i>
                    <p pan="M16_HeadNav_User_Coupend" class="__r_c_">您有<b id="willEndCount">0</b>张优惠券即将过期 <a
                            href="http://my.mtime.com/account/voucher/ecommerce/" id="urlEcommerceOrMovie">点击查看</a></p>
                </div>
                <ul class="my-app">
                    <li pan="M16_HeadNav_User_MyMtime" class="__r_c_"><p>我的：<a
                            href="http://my.mtime.com/app/blog/">博客</a><em>|</em><a
                            href="http://my.mtime.com/app/group/">群组</a><em>|</em><a href="http://my.mtime.com/movie/">电影</a><em>|</em><a
                            href="http://my.mtime.com/favorite/">收藏</a></p>
                        <p>游戏：<a href="http://my.mtime.com/app/card/">卡片大富翁</a><em>|</em><a
                                href="http://my.mtime.com/app/quiz/">猜电影</a></p></li>
                    <li class="fix"><a href="javascript:void(0);" class="btngrey __r_c_" pan="M16_HeadNav_User_Signout">登出</a><a
                            href="http://my.mtime.com/profile/basic/" class="__r_c_" pan="M16_HeadNav_User_ChangeId">修改资料</a><em>|</em><a
                            href="http://my.mtime.com/profile/password/" class="__r_c_" pan="M16_HeadNav_User_ChangePw">密码</a>
                    </li>
                </ul>
            </div>
        </div>
        <div class="headtool" id="emailbox" style=""><i class="line"></i><a href="javascript:void(0)"
                                                                            class="headmessage" id="headmessage"><i></i><em
                class="ico-message"></em></a></div>
        <div class="headtool" id="appDownloadbox"><i class="line"></i><a href="javascript:void(0)" class="headqr"
                                                                         onclick="headTrackClick(&#39;M16_HeadNav_Qrcode_Btn&#39;)"
                                                                         pan="M16_HeadNav_Qrcode_Btn"><i></i><em
                class="ico-app"></em><span>App下载</span><b></b></a>
            <div class="headtip qrcode-tip" style="display:none;"><a href="http://feature.mtime.com/mobile/"
                                                                     target="_blank"
                                                                     onclick="headTrackClick(&#39;M16_HeadNav_Qrcode_Down&#39;)"
                                                                     pan="M16_HeadNav_Qrcode_Down"><i class="qrcode"
                                                                                                      id="qrcodeimg"><img
                    src="./我的账户 - Mtime时光网_files/200851.63552497_o.jpg" alt="扫描二维码下载APP"></i></a></div>
        </div>
        <div class="headtool" id="searchbox"><a href="javascript:void(0)" class="headzoom"><em class="zoom" title="搜索"
                                                                                               pan="M16_HeadNav_Sreach_Tool_Zoom"></em></a>
            <div class="headsearch" style="width:395px;display:none;">
                <div class="topsearch">
                    <div class="searchshadow">
                        <div class="selctsearch"><strong>全部</strong><i></i><span>|</span></div>
                        <div class="selectshow" style="display:none;">
                            <ul>
                                <li searchtype="0" pan="M16_HeadNav_Search_type0" class="__r_c_">全部</li>
                                <li searchtype="1" pan="M16_HeadNav_Search_type1" class="__r_c_">电影</li>
                                <li searchtype="3" pan="M16_HeadNav_Search_type3" class="__r_c_">影人</li>
                                <li searchtype="2" pan="M16_HeadNav_Search_type2" class="__r_c_">影院</li>
                                <li searchtype="4" pan="M16_HeadNav_Search_type4" class="__r_c_">商品</li>
                                <li searchtype="5" pan="M16_HeadNav_Search_type5" class="__r_c_">新闻</li>
                            </ul>
                        </div>
                        <input type="text" class="text c_a5" value="" autocomplete="off"><a href="javascript:void(0);"
                                                                                            class="button __r_c_"
                                                                                            title="搜索"
                                                                                            pan="M16_HeadNav_Search_Btn_0"><i></i></a>
                    </div>
                    <div class="showsearch" style="display:none;"></div>
                </div>
            </div>
        </div>
    </div> -->
</div>
</div>
<div id="managerHistoryRegion"></div>
<!--head -->
<div id="div_cardgold" style="display:none"></div>
<div id="M14_B_MyMtime_BannerTG"></div>    <!--head end -->
<div id="appRegion"> <!--背影蓝色-->
    <div class="my_bgblue"></div> <!--导航与内容距离-->
    <div class="my_add"></div>
    <div class="my_shadow">
        <div class="my_head">
            <div id="welcomeRegion"><h2><a href="http://my.mtime.com/account/">我的账户</a><span class="px18 bold"></span>
            </h2></div>
            <div id="headerBgRegion" class="i_pop"></div>
        </div>
        <div class="my_box">
            <div class="account_nav clearfix yahei">
                <div class="my_account fl clearfix">
                    <div class="my_photo fl"><a href="" title="" target="_blank">
                        <img id="userimg"  width="112" height="112" src=""> </a> <a
                            href="Userinfo.html" class="ico_my_edit">&nbsp;</a></div>
                    <!--photo end-->
                    <dl class="my_info fl">
                        <dt id="nickName">认真的马场彻</dt>
                        <dd> 账户余额：<b class="price">￥<em id="availableSum">0.00</em></b></dd>
                    </dl>
                </div>    <!--myaccount end-->
                <ul class="my_menu fr clearfix">
                    <li class="curr"><a href="http://my.mtime.com/account/"> <b class="my_order">&nbsp;</b> 我的电影票 <em>&nbsp;</em>
                    </a></li>
                    <li class=""><a href="http://my.mtime.com/account/ecommerce/orderList/"> <b
                            class="my_shop">&nbsp;</b> 我的商品 <em>&nbsp;</em> </a></li>
                    <li class=""><a href="http://my.mtime.com/account/voucher/"> <b class="my_coupons">&nbsp;</b> 我的优惠券
                        <em>&nbsp;</em> </a></li>
                    <li class=""><a href="http://my.mtime.com/account/moviecard/"> <b class="my_moviecard">&nbsp;</b>
                        我的礼品卡 <em>&nbsp;</em> </a></li>
                    <li class=""><a href="http://my.mtime.com/account/address/"> <b class="my_address">&nbsp;</b> 我的地址
                        <em>&nbsp;</em> </a></li>
                </ul>    <!--mymenu end-->    </div>    <!--account_nav end-->
            <div class="midbox">
                <div class="toptit yahei"><a href="http://my.mtime.com/account/order/" class="fr">查看全部订单&gt;&gt;</a>
                    <h2>最近订单</h2></div>    <!--订单列表-->
                <div id="orderListDiv">
                    <table id="tableRegion" width="100%" border="0" cellspacing="0" cellpadding="0"
                           class="acct_order mt20 new_order">
                        <tbody id="order_List">
                        	
                        </tbody>
                    </table>
                    <div class="page" id="page_order" ></div>
                   <!--  <p class="mt12 tr"><strong>注：</strong>您最近有<strong class="c_red">4</strong>笔订单记录，<strong
                            id="unpaidCountStrong" class="c_red">1</strong>笔待付款。 </p></div>   -->      <!--正在热映-->
              
            <div style="opacity: 0.6; filter: alpha(opacity=60); zoom: 1; z-index: 110; position: fixed; margin: 0px; padding: 0px; top: 0px; left: 0px; width: 100%; height: 100%; background: rgb(0, 0, 0); display:none;"
                 id="bgLayer"></div>
            <div class="custicketbox" id="ticketLayer" style="display:none;"><a class="close" href="javascript:void(0)"
                                                                                method="closeTicketLayer">关闭</a>
                <div class="custicketinner"></div>
            </div>    <!--midbox end-->    </div>
    </div> <!--my_shadow end-->
    <div class="toolpop">
        <ul>
            <!--<li><a href="http://feature.mtime.com/chat" target="_blank"><i class="ico_onlineseek">&nbsp;</i>在线咨询</a></li>	<li class="a01"><a id="onlineServiceLink" href="#" target="_blank" onclick="return false;"><i class="ico_onlinemessage">&nbsp;</i>在线留言</a></li>	<li class="last"><a href="http://my.mtime.com/message/onlinemessage" target="_blank"><i class="ico_reply">&nbsp;</i>留言回复</a></li>-->
            <li><a href="javascript:void(0)" id="onlineServiceLink"><i class="ico_kefu"></i>在线客服</a></li>
        </ul>
    </div>
</div>
<div id="bottom" style="">
    <div class="footout"><span class="topline"></span>
       <div class="footinner clearfix">
            <div class="fotlogo">
                <dl>
                    <dt><a href="http://www.mtime.com/" title="Mtime时光网">Mtime时光网</a></dt>
                    <dd class="clearfix"><a href="https://app.mokahr.com/apply/mtime">加入我们</a><a
                            href="http://feature.mtime.com/help/contact.htm" class="ml30">联系我们</a></dd>
                    <dd class="clearfix"><a href="http://group.mtime.com/help/">站务论坛</a><a
                            href="http://my.mtime.com/reportError/" class="ml30">问题反馈</a></dd>
                    <dd class="clearfix"><a href="http://feature.mtime.com/help/rules.htm">社区准则</a><a
                            href="http://www.mtime.com/sitemap.htm" class="ml30">网站地图</a></dd>
                    <dd class="clearfix"><a href="http://feature.mtime.com/help/privacy.htm">隐私政策</a><a
                            href="http://en.mtime.com/" class="ml30">English</a></dd>
                </dl>
                <i class="line"></i></div>
            <div class="fotmap">
                <dl style="width:42px;">
                    <dt>栏目</dt>
                    <dd><a href="http://news.mtime.com/">新闻</a></dd>
                    <dd><a href="http://theater.mtime.com/">影院</a></dd>
                    <dd><a href="http://mall.mtime.com/">商城</a></dd>
                    <dd><a href="http://www.mtime.com/community/">社区</a></dd>
                </dl>
                <dl style="width:185px;">
                    <dt>推荐</dt>
                    <dd><a href="http://movie.mtime.com/recent/">观影指南</a><a href="http://movie.mtime.com/boxoffice/"
                                                                            class="ml30">电影票房</a></dd>
                    <dd><a href="http://news.mtime.com/conversation/">时光对话</a><a
                            href="http://video.mtime.com/search/?h=video&amp;s=2&amp;t=%E9%A2%84%E5%91%8A%E7%89%87"
                            class="ml30">新片预告</a></dd>
                    <dd><a href="http://movie.mtime.com/all/list/index.html">特色榜单</a><a
                            href="http://my.mtime.com/app/quiz/" class="ml30">电影猜猜猜</a></dd>
                    <dd><a href="http://news.mtime.com/fun/">全球拾趣</a><a href="http://my.mtime.com/app/card/"
                                                                        class="ml30">卡片大富翁</a></dd>
                </dl>
                <dl>
                    <dt>关注我们</dt>
                    <dd><a href="http://weibo.com/movietime?topnav=1&amp;wvr=5&amp;topsug=1" target="_blank"
                           class="sina" title="新浪">新浪</a></dd>
                    <dd><a id="aWeiXinPicButton" href="javascript:void(0)" class="weixin" title="微信">微信</a></dd>
                    <dd><a href="http://www.mtime.com/rss/" target="_blank" class="rss" title="RSS">RSS</a></dd>
                </dl>
                <i class="line"></i>
                <div id="divWeiXinPicContainer" class="my_layer" style="display: none;"><em class="l_arrow">&nbsp;</em>
                    <div class="inner p15" style="width:195px;"><i></i>
                        <p>扫描二维码，微信实时关注时光网</p></div>
                </div>
            </div>
            <div class="fotweek">
                <dl>
                    <dt class="clearfix"><span class="fr">第212期</span><strong>时光周刊</strong></dt>
                    <dd><a href="http://www.mtime.com/weekly/" target="_blank" title="时光周刊"><img
                            src="./我的账户 - Mtime时光网_files/155934.32319019_o.jpg" width="170" alt="时光周刊"></a></dd>
                    <dd class="input"><input id="iptEMail" type="text" value="邮箱地址" class="c_a5"><a id="btnSubscribe"
                                                                                                    href="javascript:void(0)">订阅</a>
                    </dd>
                </dl>
            </div>
            <div class="fothr">
                <dl>
                    <dt><strong>手机购票</strong> 方便 实惠</dt>
                    <dd><a href="http://feature.mtime.com/mobile/" target="_blank"><i></i></a></dd>
                    <dd>扫描二维码 下载客户端</dd>
                </dl>
            </div>
        </div>
    </div>
    </div>
    <div class="db_foot"><p><span class="mr12">北京动艺时光网络科技有限公司</span>Copyright 2006-2018 Mtime.com Inc. All rights
        reserved.<br><a href="http://feature.mtime.com/help/icp.htm" target="_blank" class="mr12 ml12">京ICP证050715号</a>
        <a href="http://feature.mtime.com/help/videolicence.htm" target="_blank" class="mr12">网络视听许可证0108265号</a><a
                href="http://feature.mtime.com/help/network.htm" target="_blank" class="mr12">网络文化经营许可证</a><a
                href="http://feature.mtime.com/help/tvlicence.htm" target="_blank"
                class="mr12">广播电视节目制作经营许可证(京)字第1435号</a><span>京公网安备：110105000744号</span></p>
        <div class="credible"><a href="http://feature.mtime.com/help/credible.htm" target="_blank" title="可信网站"
                                 class="credibler"></a><a href="http://feature.mtime.com/help/goodfaith.htm"
                                                          target="_blank" title="诚信网站" class="goodfaith"></a></div>
    </div>
</div>
<div id="contentEnd">
    <embed type="application/x-shockwave-flash"
           src="http://static1.mtime.cn/20180730161010/flash/MtimeCallback.swf?rnd=11740883" width="1" height="1"
           id="flashCallback" name="flashCallback" quality="high" menu="false" allowfullscreen="false"
           allowscriptaccess="always" wmode="transparent">
</div>

<!-- <div class="floatlayer" style="margin-left:-500px; display:none;">
    <table width="1000" border="0" cellspacing="0" cellpadding="0" class="acct_order">
        <tbody>
        <tr>
            <th>商品摘要</th>
            <th width="100">订单金额</th>
            <th width="240">订单状态</th>
            <th width="100">支付状态</th>
            <th width="80">操作</th>
        </tr>
        </tbody>
    </table>
</div> -->



 <script id="template_order" type="text/html">
		<tr>
            <th>商品摘要</th>
            <th width="100">订单金额</th>
            <th width="240">订单状态</th>
            <th width="100">支付状态</th>
            <th width="80">操作</th>
        </tr>
		{{# for(var i=0;i<d.length;i++){ }}
			
			{{# if(d[i].orderIsActive.id == 1){ }}
				
						<tr class="curr"  >
                            <td colspan="5"  id="auto_order_cancel{{i}}" data-id="{{ d[i].id }}"  ><span class="fr">{{ d[i].buyDate }}</span> <strong>订单号：</strong>{{ d[i].id }}</td>
                        </tr>
					<tr class="curr01"> 
                            <td>
                                <div class="mypic clearfix">
                                    <div class="photo fl"><img src="{{ d[i].schedule.poster }}" width=80px height=115px >
                                    </div>
                                    <ul class="my_txt fl">
                                        <li>电影票:{{ d[i].schedule.movieName }}</li>
                                        <li>{{ d[i].schedule.price }}元/张 共{{ d[i].count }}张</li>
										<li>影厅：{{ d[i].schedule.description  }} </li>
										<li>{{ d[i].schedule.showTime }}</li>
										<li>座位：{{# for(var j=0;j<d[i].seatList.length;j++){ }}
													{{ d[i].seatList[j].row }}排{{ d[i].seatList[j].line }}座
												{{# } }}								
										</li>
										
                                    </ul>
                                </div>
                            </td>
                            <td><p class="px14 tc yahei">￥{{ d[i].adjustedPrice }}</p></td>
                            <td countdown="{{ d[i].buyDate }}"><p class="tc pay_ico"><strong
                                    class="order_status">已创建</strong></p>
                                	<div class="acct_times yahei" id="ioc_auto_order_cancel{{i}}"  ><p id="status_auto_order_cancel{{i}}"><i class="ml4">0</i ><i>0</i><i></i><i
                                        ></i><i class="ml4"></i><i></i></p>
                                    <p><em>时</em><em class="ml5">分</em><em class="ml5">秒</em></p></div>
                            </td>
                            <td align="center" class="color">未支付</td>
                            <td class="tc"><p id="pay_{{ d[i].id }}" class="mt6"><a
                                    href="/moviesMaven/alipay/index.jsp?count={{ d[i].count }}&movieName={{ d[i].schedule.movieName }}&price={{ d[i].adjustedPrice }}&orderId={{ d[i].id }} " target="_blank">付款</a></p>
                                <p class="mt6"><a data-name="orderoff"  onclick="orderoff({{ d[i].id }})" _type="online"
                                                  href="javascript:void(0)">取消订单</a>
                                </p></td>
                   </tr> 
				
			
			{{# }else if (d[i].orderIsActive.id  == 2 || d[i].orderIsActive.id == 3) { }}
						<tr class="curr">
                            <td colspan="5"><span class="fr">{{ d[i].buyDate }}</span> <strong>订单号：</strong>{{ d[i].id }}</td>
                        </tr>
                        <tr class=""> 
                            <td>
                                <div class="mypic clearfix">
                                    <div class="photo fl"><img src="{{ d[i].schedule.poster }}" width=80px height=115px >
                                    </div>
                                    <ul class="my_txt fl">
                                        <li>电影票:{{ d[i].schedule.movieName }}</li>
                                        <li>{{ d[i].schedule.price }}元/张 共{{ d[i].count }}张</li>
										<li>影厅：{{ d[i].schedule.description  }} </li>
										<li>{{ d[i].schedule.showTime }}</li>
										<li>座位：{{# for(var j=0;j<d[i].seatList.length;j++){ }}
													{{ d[i].seatList[j].row }}排{{ d[i].seatList[j].line }}座
												{{# } }}								
										</li>
										
                                    </ul>
                                </div>
                            </td>
                            <td><p class="px14 tc yahei">￥{{ d[i].adjustedPrice }}</p></td>
                            <td><p class="tc pay_ico"><strong class="order_status">
									{{# if(d[i].orderIsActive.id==2){  }}
									交易成功
									{{# }else{ }}
									已取消
									{{# } }}

									</strong></p></td>
                            <td align="center" class="color">
								{{# if(d[i].orderIsActive.id==2){ }}
									已支付
								{{# }else{ }}
									未支付
								{{# } }}
							</td>
                            <td class="tc">  
                                <p class="mt6"><a method="orderdel" _type="online" onclick="orderdel({{ d[i].id }})"
                                                  href="javascript:void(0)">删除订单</a>
                                </p></td>
                 </tr>
				


			{{# } }}

		{{# } }}	
	
</script>

	
<script  src="../static/js/jquery-3.3.1.js"></script>
<script  src="../static/js/layer/layer.js"></script>
<script  src="../static/js/layui/layui.js"></script>
<script src="../static/js/test.js"></script>

<script  type="text/javascript" >
	 //页面加载时就运行
    	$(function(){
    		
    		getUserId();
    		getUrlData();
    		frist(); 	 		 //首栏
    		
    	});

	 
   	 var userId="";
	 //获取session用户手机号码
	 function getUserId(){
    		$.ajax({
    			url:"/moviesMaven/getLoginUser.htm",
    			dataType:"json",
    			success:function(data){
    				if(data.success){
    					userId=data.result.id;
    					getOrderCount(data.result.id);
    				}else{
    					window.location.replace("../toLogin2.html");
    				}
    			},
    			error:function(){
    				layer.msg("查询订单总数出错！");
    			}
    			
    		});
    	}
	 

	 
    	//获取订单总数
    	function getOrderCount(userId){
    		
    		$.ajax({
    			url:"/moviesMaven/order/getOrderCount.htm",
    			dataType:"json",
    			data:{"userId":userId},
    			success:function(data){
    				renderPage_order(data.result);
    			},
    			error:function(){
    				layer.msg("查询订单总数出错！");
    			}
    			
    		});
    	}
    	
    	//渲染分页元素
    	function renderPage_order(data){
    			var count = data; //总数
    			var size = 3; //每页行数
    			
    			//渲染分页
    			layui.use("laypage", function() {
    				var laypage = layui.laypage;
    				
    				laypage.render({
    					
    					elem : "page_order",
    					count :count,
    					limit : size,
    					theme : "#4287c2",
    					jump : function(obj, first) {
							
							getdata_order(obj.curr,size);
							
						}
	
    				});

    			});
    	}
    	
    	//获取订单数据
    	function getdata_order(nowPage,size){
    		
    		
    	 $.ajax({
                url:"/moviesMaven/order/getOrderList.htm",
                dataType:"json",
                data:{
					"nowPage" : nowPage,
					"size" : size,
					"userId":userId
					},
                success:function (data) {
					
                    if(data.success){
                    	$("#nickName").html((data.result)[0].user.nickName); 
                    	$("#userimg").attr("src", (data.result)[0].user.headPortrait);
                    	
                    	/* 渲染页面 */
	 					renderData_order(data.result);
                    	
                   		 
                    }else {
                        layer.msg(data.message);
                    }
                },
                error:function () {
                    layer.msg("查询出错");
                }
            }); 

    	}
    	
    	//模板引擎渲染页面
    	function  renderData_order(data){
    		
    		layui.use("laytpl",function(){
    			var laytpl = layui.laytpl;
    			
    			var template_order = $("#template_order").html();
    			laytpl(template_order).render(data,function(html){
    				$("#order_List").html(html);
			
    			});
    			
    			getId();
    		});
    		
    		
    	}
    	
    	//获取未付款的
    	function getId(){
    		
    		$("td[id^=auto_order_cancel]").each(function(index, element) {
                var id=$(this).attr("id");            //标签id
                var orderId = $(this).attr("data-id");  //订单id
                var DateStr = $("#"+id+" span").text();  //待付款的订单时间
                setTime(id,orderId,DateStr);
            });
    		
    	}
    	
    	//给未付款的订单添加倒计时
      function setTime(id,orderId,DateStr){
    	 
    	   function _fresh(){
               var nowDate = new Date();//当前时间
               var buyData = new Date(DateStr);  //下单时间
               
               var auto_totalS=15*60;   //15分钟的总秒数
               var ad_totalS  = parseInt((buyData.getTime()/1000)+auto_totalS);  ///下单总秒数
               var totalS   = parseInt(ad_totalS-(nowDate.getTime()/ 1000));//剩余支付时长
				
               if(totalS>0){
                       var _hour   = parseInt((totalS / 3600) % 24)+"";
                       var _minute = parseInt((totalS / 60) % 60)+"";
                       var _second = parseInt(totalS % 60)+"";
                       
                       var m1 =_minute.substring(0,1);
                       var m2 =_minute.substring(1,2);
                       
                       var s1 = _second.substring(0,1);
                       var s2 = _second.substring(1,2);
                       
                       if(m2==""){
                    	   $('#status_'+id+' i:eq(2)').html("0");
                           $('#status_'+id+' i:eq(3)').html(m1);
                       }else{
                    	   $('#status_'+id+' i:eq(2)').html(m1);
                           $('#status_'+id+' i:eq(3)').html(m2);
                       }
                       
                       if(s2==""){
                    	   $('#status_'+id+' i:eq(4)').html("0");
                           $('#status_'+id+' i:eq(5)').html(s1); 
                       }else{
                    	   $('#status_'+id+' i:eq(4)').html(s1);
                           $('#status_'+id+' i:eq(5)').html(s2); 
                       }
                     
                       /* $('#ico_'+id).show(); */

                   }else{//支付超时
                	   
                	   $.ajax({
                           url:"/moviesMaven/order/getOrderIsActiveId.htm",
                           dataType:"json",
                           data:{"orderId":orderId},
                           success:function(data){
                              if(data.result==1){
                            	   $('#status_'+id+' i').html('');
                            	   $('#ioc_'+id).remove();
                                   clearInterval(sh);    //取消自增效果
                                   autoOrderOff(orderId); //调用取消订单方法
                                   autoOrderSeatOff(orderId); //调用取消已订座位方法
                               }else{
                            	   clearInterval(sh);
                            	   getOrderCount(userId);
                               }      
                           },
                           error:function () {
                               layer.msg("更新出错");
                           }
                       });  

          			 }
           
       		}
    	 _fresh();
         var sh = setInterval(_fresh,1000);
    }
    //倒计时自动取消订单	
   function autoOrderOff(orderId){
	   var num = 3;
	   $.ajax({
           url:"/moviesMaven/order/updateOrder.htm",
           dataType:"json",
           data:{"orderId":orderId,"activeId":num},
           success:function(data){
               if(data.success){
            	   getOrderCount(userId);  
           				
               }else{
            	   layer.msg(data.message);
               }
           },
           error:function () {
               layer.msg("更新订单出错");
           }
       }); 
	   
   }
    //倒计时自动取消已订座位
    function autoOrderSeatOff(orderId){
    	   $.ajax({
               url:"/moviesMaven/html/seat/updateOrderSeat.htm",
               dataType:"json",
               data:{"orderId":orderId},
               success:function(data){
                   if(data.success){
                	   
                	   getOrderCount(userId);  

                   }else{
                	   layer.msg(data.message);
                   }
               },
               error:function () {
                   layer.msg("更新已订座位出错");
               }
           }); 
    	
    }
   	
    //点击取消事件	修改状态为3 
   	function orderoff(orderId){
    	 layer.open({
    		title:"确认",
    		icon:3,
    		content: "您确定要取消此订单吗？",
    		btn: ['确定','取消'],
    		yes:function(index){
    			autoOrderOff(orderId);   //调用取消订单方法
    			autoOrderSeatOff(orderId); //调用取消已订座位方法
    			layer.close(index);
    		},
    		btn2: function(index){
    			layer.close(index);
			 },
			cancel:function(index){
				layer.close(index);
			}
		}); 
  	
    };
    
    //点击删除事件	 修改状态为4
    function orderdel(orderId){
    	var num = 4;
    	
    	layer.open({
    		title:"确认",
    		icon:3,
    		content: "您确定要删除此订单吗？删除后将不在列表显示！",
    		btn: ['确定','取消'],
    		yes:function(index){
    			 $.ajax({
    	               url:"/moviesMaven/order/updateOrder.htm",
    	               type:'post',
                       dataType:"json",
                       data:{"orderId":orderId,"activeId":num},
    	               success:function(data){
    	                   if(data.success){
    	                	   getOrderCount(userId);
    	                   }else{
        	            	   layer.msg(data.message);
        	               }
    	                   layer.close(index);
    	               }
    	           }); 
    			 
    			 $.ajax({
    	             url:"/moviesMaven/order/getOrderIsActiveId.htm",
    	             type:'post',
    	             dataType:"json",
    	             data:{"orderId":orderId},
    	             success:function(data){
    	                 if(data.result==3){
    	                	 autoOrderSeatOff(orderId)
    	                 }
    	                 
    	             }
    	         }); 
    			 
    			},
    			btn2: function(index){
    				layer.close(index);
    			 },
    			cancel:function(index){
    				layer.close(index);
    			}
    		});
    	
    	
    	 
    }
    
      function getUrlData(){
    	var url = String(window.location.href); //获取url
		var temp = url.split('?'); 
    	if(temp[1]!=null && temp[1]!=""){
    		var data = temp[1].split('&');
    		var orderId = data[0].substring(data[0].indexOf('=')+1,data[0].length);   //订单Id
    		var price = data[1].substring(data[1].indexOf('=')+1,data[1].length);  //总价格
    		 $.ajax({
	             url:"/moviesMaven/order/getOrderIsActiveId.htm",
	             type:'post',
	             dataType:"json",
	             data:{"orderId":orderId},
	             success:function(data){
	                 if(data.result==1){
	                	 updateOrder(orderId,2);
	                 }
	                 
	             }
	         }); 
    	}
		
    } 
      
    function updateOrder(orderId,activeId){
    	
    	 $.ajax({
             url:"/moviesMaven/order/updateOrder.htm",
             type:'post',
             dataType:"json",
             data:{"orderId":orderId,"activeId":activeId},
             success:function(data){
                 if(data.success){
              	   getOrderCount(userId);
                 }else{
	            	   layer.msg(data.message);
	               }
                
             }
         }); 
    }
    
 //首栏
    function frist(){
    	var liftPage = $("#frist").attr("page");
    	$("#frist").load(liftPage);
    }; 
 

</script>


</body>
</html>